//
//  MessageListContentCell.m
//  lixing
//
//  Created by zoulv on 2021/12/19.
//

#import "LXMessageListContentCell.h"
#import "LXSystemMsgModel.h"
@implementation LXMessageListContentCell

- (void)awakeFromNib {
    [super awakeFromNib];
    self.contentView.backgroundColor = ColorWithF5F5F5;
    [self.markV addCorner:self.markV.height/2];
    [self.markV2 addCorner:self.markV2.height/2];
    [self.markV3 addCorner:self.markV2.height/2];
    [self.contentBGV addCorner:5];
    [self.contentBGV2 addCorner:5];
    [self.contentBGV3 addCorner:5];
    
    [self.buCarL3 addCorner:3 AndLine:[ColorWith3C6CFC colorWithAlphaComponent:0.1]];
    
}

- (void)setModel1:(LXSystemMsgModel *)model1{
    _model1 = model1;
    
    self.titleL.text = model1.title;
    

    self.contentL.text = model1.content;
    self.contentL.lineSpace = 5;

    self.timeL.text = model1.createTimeStr;
    self.markV.hidden = YES;

}

- (void)setModel2:(LXSystemMsgModel *)model2{
    _model2 = model2;


    self.titleL2.text = model2.title;
    self.contentL2.text = model2.content;
    self.contentL2.lineSpace = 5;
    self.markV2.hidden = YES;
    self.timeL2.text = model2.createTimeStr;
    
}
- (void)setModel3:(LXSystemMsgModel *)model3{
    _model3 = model3;

    self.iconImageV3.image = [UIImage imageNamed:@"buCarMessage"];
    self.titleL3.text = model3.title;
    self.contentL3.text = model3.content;
    self.contentL3.lineSpace = 5;
    self.markV3.hidden = YES;
    self.timeL3.text = model3.createTimeStr;
    
    
    if (model3.carTypeFlag == 1) {
        self.buCarL3.backgroundColor = ColorWithAAAAAA;
        self.buCarL3.textColor = ColorWithF5F5F5;
    }
    else {
        self.buCarL3.backgroundColor = [ColorWith3C6CFC colorWithAlphaComponent:0.1];
        self.buCarL3.textColor = ColorWith3C6CFC;
    }
}
@end
